package com.example.demo.pojo;

import java.io.Serializable;

import javax.persistence.Column;
import javax.persistence.EmbeddedId;
import javax.persistence.Entity;
import javax.persistence.Id;
import javax.persistence.IdClass;

import lombok.Getter;
import lombok.Setter;
import lombok.ToString;

@Entity
@javax.persistence.Table(name="userLike")
@Setter
@Getter
@ToString
@IdClass(Zhujian.class)
public class Like implements Serializable{
	@Id
	String userId;
	@Id
	String goodId;
	@Column(name = "price", nullable = true, length = 40)
	String price;
	@Column(name = "num", nullable = true, length = 40)
	String num;
	@Column(name = "title", nullable = true, length = 300)
	String title;
	@Column(name = "image", nullable = true, length = 300)
	String image;

	public String getUserId() {
		return userId;
	}
	public void setUserId(String userId) {
		this.userId = userId;
	}
	public String getGoodId() {
		return goodId;
	}
	public void setGoodId(String goodId) {
		this.goodId = goodId;
	}
	public String getPrice() {
		return price;
	}
	public void setPrice(String price) {
		this.price = price;
	}
	public String getNum() {
		return num;
	}
	public void setNum(String num) {
		this.num = num;
	}
	public String getTitle() {
		return title;
	}
	public void setTitle(String title) {
		this.title = title;
	}
	
	public String getImage() {
		return image;
	}
	public void setImage(String image) {
		this.image = image;
	}
	@Override
	public String toString() {
		return "Like [userId=" + userId + ", goodId=" + goodId + ", price=" + price + ", num=" + num + ", title="
				+ title + ", image=" + image + "]";
	}
	
}
